package com.kuang.springcloud.controller;


import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
//刷新的  curl -X POST "http://localhost:8001/actuator/refresh"
@RefreshScope
public class PaymentController
{
    @Value("${info.name}")
private String infoName;
    @Value("${info.version}")
    private String infoVersion;
    @GetMapping("/info")
    public String getInfoName(){
        return infoName+"\t version"+infoVersion;
    }

}
